
		{template 'common/header'} 
		<div class="panel panel-info">
	<div class="panel-heading" style="text-align: center;">活动内容</div>
	<div class="panel-body">
		 <form  class="form-horizontal" id="form1" name="form1" method="post" action="<?php echo $this->createWebUrl('addactivity');?>" enctype="multipart/form-data" >
		 <div class="form-group">
		    <label for="inputEmail3" class="col-sm-4 control-label">活动名称:</label>
		    <div class="col-sm-4">
		    <input type="text" class="form-control" id="activityname" name="activityname" placeholder="活动名称">
		    </div> 
		    <label for="inputEmail3" class="col-sm-1 control-label" style="color:orange;text-align: left;">&nbsp;*必填</label>
		  </div> 
		  <div class="form-group">
		    <label for="inputEmail3" class="col-sm-4 control-label">活动图片:</label>
		    <div class="col-sm-4">
	          {php echo tpl_form_field_image('picture');}
		    </div> 
		    <label for="inputEmail3" class="col-sm-1 control-label" style="color:orange;text-align: left;">&nbsp;*必填</label>
		  </div> 
		  <div class="form-group">
		    <label for="inputEmail3" class="col-sm-4 control-label">活动时间:</label>
		    <div class="col-sm-4">
		   <input type="datetime-local" class="form-control" id="starttime"  name="starttime" />到<input type="datetime-local" class="form-control" id="endtime" name="endtime" />
		  </div>  
		  <label for="inputEmail3" class="col-sm-1 control-label" style="color:orange;text-align: left;">&nbsp;*必填</label>
		   </div> 
		  <div class="form-group">
		    <label for="inputEmail3" class="col-sm-4 control-label">兑奖时间:</label>
		    <div class="col-sm-4">
		   <input type="datetime-local" class="form-control" id="tstarttime" name="tstarttime" />到<input type="datetime-local" class="form-control" id="tendtime" name="tendtime" />
		    </div> 
		    <label for="inputEmail3" class="col-sm-1 control-label" style="color:orange;text-align: left;">&nbsp;*必填</label>
		  </div> 
		  <div class="form-group">
		    <label for="inputEmail3" class="col-sm-4 control-label">活动说明:</label>
		    <div class="col-sm-4">
		    <textarea class="form-control" name="activity_desc" id="activity_desc"></textarea>
		    </div> 
		  </div>
		  <div class="form-group">
		    <label for="inputEmail3" class="col-sm-4 control-label">最终解释权:</label>
		    <div class="col-sm-4">
		    <textarea class="form-control" name="power" id="power"></textarea>
		    </div> 
		    <label for="inputEmail3" class="col-sm-1 control-label" style="color:orange;text-align: left;">&nbsp;*必填</label>
		  </div>
		  <div class="form-group col-xs-12 col-md-12 " style="text-align:center;" >
		    <input type="button"  class="form-control" style="width:
		   100px;margin:0 auto; color: blue;"  value="提交" onclick="sub()" />
		  </div>
		  </form>
	</div>
	</div>
</div> 
<script type="text/javascript">
var temp=true;
function sub(){
 if($("#activityname").val()==''){
 alert("活动名称不能为空");
 temp=false;
 return temp;
 }
 if($("#starttime").val()==''){
 alert("活动开始时间不能为空");
 temp=false;
 return temp;
 }
 if($("#endtime").val()==''){
 alert("活动结束时间不能为空");
 temp=false;
 return temp;
 }
 if($("#tstarttime").val()==''){
 alert("兑奖开始时间不能为空");
 temp=false;
 return temp;
 }
 if($("#tendtime").val()==''){
 alert("兑奖结束时间不能为空");
 temp=false;
 return temp;
 }
 if($("#power").val()==''){
 alert("解释权不能为空");
 temp=false;
 return temp;
 }
 $("#form1").submit();
}
</script>    
	{template 'common/footer'}

